<?php
namespace src;
use \classlib\core\router;
class CSitemap {
	public function main() {
		$uri  = router::base_url();
		$xml  = '<?xml version="1.0" encoding="UTF-8"?>';
		$xml .= '<urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9">';
		$xml .= '<url>';
		$xml .= '<loc>'.$uri.'</loc>';
		$xml .= '<lastmod>'.date('Y-m-d').'</lastmod>';
		$xml .= '<changefreq>daily</changefreq>';
		$xml .= '<priority>1.0</priority>';
		$xml .= '</url>';
		$xml .= '</urlset>';
		ob_end_clean();
		header("Content-type:text/xml");
		echo $xml;
	}
}